package com.example.homework1.controller;

import org.springframework.stereotype.Controller;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.ResponseBody;

@Controller
@ResponseBody
@RequestMapping("/square")
public class SquareController {
    @GetMapping("/4")
    public int square(){
        int num = 4;
        int square = num*num;
        return square;
    }
}
